<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>行元素</title>
    <style>
        /* 无法设置宽高 */
        .span1 {
            width: 100px;
            height: 100px;
            font-size: 30px;
            background-color: red;
        }
    </style>
</head>

<body>

    <span class="span1">我是行内元素span</span>

</body>

</html>